/**  
 * @Title: GameType.java
 * @Package com.nubb.model
 * @author maoyun(maoyun0903@163.com)
 * @date 2014-3-27 下午01:36:33
 * @version V1.0
 */ 
package com.limit.model;

import java.util.List;

import com.jfinal.plugin.activerecord.Model;
import com.jfinal.plugin.ehcache.CacheKit;
import com.limit.constant.Constant;

/** 
 * 游戏类型(如： 格斗/卡牌)<br/>
 * @author maoyun(maoyun@nubb.com)
 * @date 2014-3-27 下午01:36:33 
 * @version V1.0
 */

public class GameType extends Model<GameType> {

	
	
	public final static GameType dao = new GameType();

	/** 
	 * 全部记录
	 */
	public List<GameType> getList() {
		List<GameType> types = CacheKit.get(Constant.CacheGameTypes, Constant.CacheGameTypes);
		if(null == types || types.isEmpty()){
			types = GameType.dao.find("select * from game_type order by sort_id desc");
			CacheKit.put(Constant.CacheGameTypes, Constant.CacheGameTypes, types);
			
		}
		return types;
	}
	
	
}
